package org.jl.demo.authority.model.po;

import lombok.Data;
import jakarta.persistence.*;

/**
 * 角色Po
 */
@Data
@Entity
@Table(name = "z_role", indexes = {
        @Index(name = "idx_role_code", columnList = "role_code"),
        @Index(name = "idx_role_name", columnList = "role_name")
})
public class Role {
    /**
     * 角色ID
     */
    @Id
    @Column(name = "id", nullable = false, unique = true)
    private Integer id;
    /**
     * 角色编码
     */
    @Column(name = "role_code", nullable = false, length = 8)
    private String roleCode;
    /**
     * 角色名称
     */
    @Column(name = "role_name", nullable = false, length = 32)
    private String roleName;
}